let obj = {};
let data;
Object.defineProperty(obj,'a',{
  //getter
  get(){
    console.log("你获取a");
    return data
  },
  //setter
  set(newValue){
    console.log("你设置a",newValue);
    data=newValue
  }
})
obj.a='123'
console.log("obj",obj.a)